﻿using Baula.TextGen.ActiveTemplating.Tokenizer.Tokens;

namespace Baula.TextGen.ActiveTemplating.Tokenizer.TokenParsers
{
    internal class LiteralParser : TokenParserBase
    {
        public override bool CanAppend(char c)
        {
            return c != '{';
        }

        public override void Append(char c)
        {
            StringBuilder.Append(c);
        }

        public override IToken CreateToken()
        {
            return new LiteralToken(StringBuilder.ToString());
        }
    }
}